<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
	xmlns:sec="http://www.thymeleaf.org/extras/spring-security">
<head>
<meta charset="UTF-8">
<title>首页</title>
<link rel="stylesheet" href="js/layui/css/layui.css">
</head>
<body>
	<div class="layui-col-lg6 layui-col-lg-offset3">
		<h1 style="text-align: center;">登录</h1>
		<form class="layui-form layui-form-pane" method="post"
			action="/user_login">
			<div class="layui-form-item layui-form-text">
				<label class="layui-form-label">用户名</label>
				<div class="layui-input-block">
					<input type="hidden" th:if="${_csrf != null}"
						th:name="${_csrf.parameterName}" th:value="${_csrf.token}" /> <input
						type="text" name="username" autocomplete="off" placeholder="用户名"
						class="layui-input">
				</div>
			</div>
			<div class="layui-form-item layui-form-text">
				<label class="layui-form-label">密码</label>
				<div class="layui-input-block">
					<input type="password" name="password" autocomplete="off"
						placeholder="密码" class="layui-input">
				</div>
			</div>

			<div class="layui-form-item">
				<div class="layui-input-block"
					style="text-align: center; margin-left: 0px;">
					<input type="submit" class="layui-btn" value="提交">
				</div>
			</div>
		</form>
	</div>
</body>
<script type="text/javascript" src="/js/layui/layui.js"></script>
<script type="text/javascript">
	if (window != top) {
		top.location.href = location.href;
	}
	layui.use([ 'layer' ], function() {
		var layer = layui.layer;
		var error = '[[${error}]]';
		if (error) {
			layer.msg(error);
		}
	});
</script>
</html>